package com.edward.puff.repository.impl;

import com.edward.puff.repository.PuffTransLog;
import com.edward.puff.repository.TransLogRepository;

import java.util.List;

/**
 * @Author: Edward
 * @Date: 2019/11/28 下午7:58
 */
public class EmptyRepository implements TransLogRepository {


    /**
     * 保存事务日志
     *
     * @param txLog
     */
    @Override
    public void saveTransLog(PuffTransLog txLog) {
        throw new RuntimeException("this is EmptyTransLogRepository");
    }

    /**
     * 根据txLogId,查询事务日志
     *
     * @param txLogId
     * @return
     */
    @Override
    public PuffTransLog getTransLog(String txLogId) {
        throw new RuntimeException("this is EmptyTransLogRepository");
    }

    /**
     * 查询重试TxLog
     *
     * @param count
     * @return
     */
    @Override
    public List<PuffTransLog> queryRetryTranLogs(int count) {
        throw new RuntimeException("this is EmptyTransLogRepository");
    }

    /**
     * 完结TxLog
     *
     * @param txLogId
     * @return
     */
    @Override
    public boolean finishTransLog(String txLogId) {
        throw new RuntimeException("this is EmptyTransLogRepository");
    }

    /**
     * 更新PuffTransLog
     *
     * @param txLogId
     * @return
     */
    @Override
    public boolean updateTransLog(String txLogId) {
        throw new RuntimeException("this is EmptyTransLogRepository");
    }
}
